import Vue from 'vue';
import Mint from 'mint-ui';
import VueLazyload from 'vue-lazyload';
const config = require('../../config.json');
const apiUrl = config.apiUrl
Vue.use(Mint);

//
Vue.prototype.renderImg = function(img){
    if(img){
        return `${apiUrl}/file/visit/?filename=${img}`
    }else {
        return `${apiUrl}/file/visit`
    }
};

Vue.use(VueLazyload, {
    preLoad: 1.3,
    loading: '../components/common/img/defult.jpg',
    error: '../components/common/img/defult.jpg',
});

